#:kivy 1.0
# rename this to Tickeys if using this to instead using load_string method

<Main>:
    pos: 0,0
    padding: 50
    rows: 6
    row_force_default: True
    row_default_height: 50
    spacing: 50
    orientation: 'vertical'

    canvas:
        Color:
            rgb: 0.42, 0.42, 0.42, 1
        Rectangle:
            pos: 0,0
            size: self.size
    Label:
        bold: True
        text: 'Tickeys'
        font_size: 42
        size_hint_y: None

    SpinnerRow
    AdjustVol
    AdjustPitch
    ExitAndSwitchRow

    InforRow


<AdjustVol>
    Label:
        bold: True
        color: 1, 1, 1, 1
        font_size: 25
        size_hint_x: None
        width: 250
        text: 'Vol:'
    Slider:
        min: 0.0
        max: 1.0
        value: 1.0
        width: 300
        on_value: root.setVolume(self.value)

<AdjustPitch>
    Label:
        bold: True
        color: 1, 1, 1, 1
        font_size: 25
        size_hint_x: None
        width: 250
        text: 'Pitch:'
    Slider:
        min: 0.0
        max: 3.0
        value: 1.0
        width: 300
        on_value: root.setPitch(self.value)


<SpinnerRow>:
    Label:
        bold: True
        color: 1, 1, 1, 1
        font_size: 25
        size_hint_x: None
        text: "Sound Effect:"
        width: 250
    EffectSpinner:
        on_text: root.change_style()


<EffectSpinner>:
    bold: True
    font_size: 25
    text: 'bubble'
    background_color: 2, 2, 2, 1
    color: 1, 1, 1, 1
    values:['bubble', 'mechanical', 'sword', 'typewriter',]

<ExitAndSwitchRow>:
    Label:
        size_hint_x: None
        width: root.width/6.0 - 120
    Label:
        size_hint_x: None
        color: 1, 1, 1, 1
        font_size: 17
        width: root.width/6.0 + 60
        text: 'Open at startup:'
    Switch:
        size_hint_x: None
        width: 40
        id: switcher
        active: root.have_added
        on_active: root.add_delete_startup_file(self.active)
    Label:
        size_hint_x: None
        width: root.width/6.0 - 35
    Button:
        size_hint_x: None
        width: 150
        background_color: 2, 2, 2, 1
        bold: True
        text: "EXIT"
        color: 0,0,0,1
        on_press: root.Exit()



<InforRow>:
    Label:
        color: 0.7, 0.7, 0.7, 1
        font_size: 23
        size_hint_x: None
        text: root.getVersion()
        width: root.width/3.0
    Label:
        color: 0.8, 0.8, 0.8, 1
        font_size: 20
        size_hint_x: None
        markup: True
        text: "[ref=->website]Project website[/ref]"
        width: root.width/3.0
        on_ref_press:root.openProjectWebsite()
    Label:
        color: 0.8, 0.8, 0.8, 1
        font_size: 18
        size_hint_x: None
        text: "Author: Bill (billo@qq.com)"
        width: root.width/3.0
        border: 1,1,1,1
        on_touch_move:
